package com.datareport.data.exception;

public enum CustomizeErrorCode implements ICustomizeErrorCode{
    TOKEN_NOT_FOUND(2001,"TOKEN异常或不存在"),
    LOGIN_HAS_EXPIRED(2002,"登录已过期，请重新登录！"),
    NO_LOGIN(2003,"当前操作需要登录，请登录后再进行操作"),
    SYS_ERROR(2004,"服务冒烟了，要不然你稍后再试试！！！"),
    USER_IS_EXIST(2005,"该用户已经存在！"),
    INSUFFICIENT_PERMISSIONS(2006,"权限不足，不允许访问"),
    USERNAME_NOT_FOUND(2007,"用户名或密码不正确");

    @Override
    public String getMessage(){
        return message;
    }

    @Override
    public Integer getCode() {
        return code;
    }

    private String message;
    private Integer code;

    CustomizeErrorCode(Integer code, String message) {
        this.message = message;
        this.code = code;
    }
}
